package com.harveyguo.nihonngo.model.entity;

import jakarta.persistence.GeneratedValue;
import jakarta.persistence.Id;
import jakarta.persistence.MappedSuperclass;
import lombok.Data;
import org.hibernate.annotations.GenericGenerator;

import java.util.Date;

/**
 * @Author：HarveyGuo
 * @Package：com.harveyguo.nihonngo.entity
 * @Project：BestReading_back
 * @name：BaseUserEntity
 * @Date：2023/2/15 17:34
 * @Filename：BaseUserEntity
 * @Describe：Do something
 */
@MappedSuperclass
@Data
public abstract class BaseUserEntity
{
    @Id
    @GeneratedValue(generator = "ksuid")
    @GenericGenerator(name = "ksuid", strategy = "com.harveyguo.nihonngo.utils.KSUIDIdentifierGenerator")
    private String id;

    private Date createTime = new Date();

    private Date updateTime = new Date();
}
